package com.elong.android.specialhouse.payment;

import com.elong.android.specialhouse.AppConstants;
import com.elong.android.specialhouse.IConfig;
import com.elong.framework.net.request.BaseRequestOption;
import com.elong.framework.netmid.api.IHusky;
import com.elong.framework.netmid.api.ReqType;

public enum PaymentExtraApi implements IHusky {
	// 团购重新获取支付参数
//	groupon_getBefundToken("getBefundToken", AppConstants.SERVER_URL_NEWGROUPON, ReqType.JAVA_GET),
//	hotel_getPayToken("getPayToken", AppConstants.SERVER_URL_NEWHOTEL, ReqType.JAVA_GET),
//	hotel_hotelOrderConfirmInfo("hotelOrderConfirmInfo", AppConstants.SERVER_URL_NEWHOTEL, ReqType.JAVA_GET),
//	hotel_CreateGlobalFlightOrder("CreateGlobalFlightOrder", AppConstants.SERVER_URL_NEWHOTEL, ReqType.JAVA_GET),

	getPayToken("order/getToken", AppConstants.SERVER_URL_HOUSE, ReqType.JAVA_GET),

	;
	private String name;
	private String url;
	private ReqType type;
	private int queneLev;

	private PaymentExtraApi(String name, String url, ReqType type) {
		this(name, url, type, BaseRequestOption.QUEUE_LEVEL_FORGROUND);
	}

	private PaymentExtraApi(String name, String url, ReqType type, int queneLev) {
		this.setName(name);
		this.setUrl(url);
		this.setType(type);
		this.setQueneLev(queneLev);
	}

	@Override
	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	@Override
	public String getUrl() {
		return IConfig.MAPI_ROOT_URL+ url;
	}

	@Override
	public void setUrl(String url) {
		this.url = url;
	}

	@Override
	public ReqType getType() {
		return type;
	}

	public void setType(ReqType type) {
		this.type = type;
	}

	@Override
	public int getQueneLev() {
		return queneLev;
	}

	public void setQueneLev(int queneLev) {
		this.queneLev = queneLev;
	}

	@Override
	public String toString() {
		return name + " " + url + " " + type + " queneLev:" + getQueneLev();
	}
}